Skip to content

QuadList class

Attributes: [DefaultMember("Item")] [DebuggerDisplay("QuadList: {Count}")]

Defined in

Namespace: ReactiveList.Reactive.Collections Assembly: ReactiveList.Reactive.dll Full name: ReactiveList.Reactive.Collections.QuadList<T> Modifiers: public sealed

Summary

View source (opens in a new tab)

Provides a high-performance, pooled list for storing elements with fast add, remove, and enumeration operations.

Applies to

net11.0, net10.0, net47, net471, net472, net48, net481

Class hierarchy
classDiagram
class QuadList~T~
class IQuad~T~ {
    <>
}
IQuad~T~ <|.. QuadList~T~
class IEnumerable~T~ {
    <>
}
IEnumerable~T~ <|.. QuadList~T~
class IEnumerable {
    <>
}
IEnumerable <|.. QuadList~T~
class IDisposable {
    <>
}
IDisposable <|.. QuadList~T~

Implements: IQuad, IEnumerable (opens in a new tab), IEnumerable (opens in a new tab), IDisposable (opens in a new tab)

Remarks

        QuadList is an internal shard optimized for scenarios where frequent additions and removals are required.
        It uses array pooling to minimize allocations. The list is not thread-safe and should not
        be accessed concurrently from multiple threads. Call Dispose to return internal arrays to the pool.
        Change notifications are NOT emitted from this class - the parent QuaternaryList handles all notifications
        through its Stream pipeline.

Constructors

NameSummary
.ctorInitializes a new instance of the QuadList class.

Properties

NameSummary
CountGets the number of elements contained in the list.
this[]Gets or sets the element at the specified index.

Methods

NameSummary
AddAdds an element to the end of the list.
RemoveRemoves the first occurrence of a specific element from the list.
RemoveAtRemoves the element at the specified index.
IndexOfReturns the zero-based index of the first occurrence of a value in the list.
ContainsDetermines whether an element is in the list.
AddRangeAdds the elements of the specified span to the end of the list.
ClearRemoves all elements from the list.
EnsureCapacityEnsures that the capacity of this list is at least the specified value.
AsSpanGets a span over the elements in the list.
CopyToCopies the elements of the list to an array starting at a particular array index.
GetEnumeratorReturns an enumerator that iterates through the list.
DisposeReturns the internal array to the pool and releases resources.
Inherited members